package com.reform.pojo.common;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

/**
 * <p>
 * 学院表
 * </p>
 *
 * @author mortale
 * @since 2021-06-27
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value="Department对象", description="学院表")
public class Department implements Serializable,Comparable<Department> {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "部门编号")
    @TableId("dep_id")
    private Integer depId;

    @ApiModelProperty(value = "部门名称")
    @TableField("dep_name")
    private String depName;

    @ApiModelProperty(value = "部门管理员")
    @TableField(exist = false)
    private String depAdmin;

    @ApiModelProperty(value = "部门授权开启")
    @TableField(exist = false)
    private Boolean depAuth;


    @Override
    public int compareTo(Department o) {
        //排序
        return this.depId.compareTo(o.getDepId());
    }
}
